#include<bits/stdc++.h>
using namespace std;
const int N=1e5+5;
int a[N];
int main()
{
    freopen("duel.in","r",stdin);
    freopen("duel.out","w",stdout);
    int n,x;
    cin>>n;
    for(int i=1;i<=n;i++)
    {
        cin>>x;
        a[x]++;
    }
    int ans=0;
    bool t=0;
    for(int i=1;i<=N;i++)
    {
        if(a[i]!=0)
        {
            if(!t)
            {
                ans+=a[i];
                t=1;
                continue;
            }
            if(ans-a[i]<0) ans=0;
            else ans-=a[i];
            ans+=a[i];
        }
    }
    cout<<ans<<endl;
    return 0;
}
